package cn.pangza.user.mapper;

import cn.pangza.user.entity.po.Menu;
import cn.pangza.user.entity.vo.MenuChildrenVo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface MenuMapper extends BaseMapper<Menu> {
    List<Menu> getMenuListByUserId(Integer id);

    List<Menu> getUserMenuWithChildren(@Param("systemUserId") Integer userId, @Param("parentId") Integer parentId);

    List<MenuChildrenVo> getMenuChildren(@Param("id") Integer id);

    List<MenuChildrenVo> getMenuChildrenAndButton(@Param("id") Integer id);

}
